#ifndef  _MODBUSFUN_HPP_
#define  _MODBUSFUN_HPP_

#include "predef.h"
#include "stdio.h"
#include "port.h"
#include "mb.h"
#include "mbconfig.h"
#include "modbus2645.h"
#include "modbusdata.h"
#include "sversion.h"
unsigned int Modbus_Init (void);
struct STMODBUS2DATAP *ModAddr2Search (unsigned short iAddr);

void InSideFunHandle (void);
int ModbusData_Init (void);
int RegKeep_init (void);
int RegKeep_Store (void);
void modbus_fun (void);
void ModbusDataFresh (void);
void RegKeep_Modapp (void);
extern const short stmodbus2data_Len;
extern const unsigned short igKeepDataDef[];
void Modbus_AppInit (void);
void modbusdata_restore_def (void);

ErrorStatus ModbusStation_Check(unsigned short iStation);
ErrorStatus ModBus_App (void);
__weak void ModbusReg_Mod_FunApp_Callback (void);
ErrorStatus Modbus_KeepDataCheck (void);
void Modbus_Register_ModFun_Handle (void);
#endif
